import request from "@/request/api";

//1.巡视工单分页查询
export function getPatrolOrderList(data) {
  return request({
    url: "/eam-service-order/patrol/queryVoPageList",
    method: "get",
    params: data,
  });
}
//2.巡视工单基本信息
export function getBasicInfo(data) {
  return request({
    url: "/eam-service-order/patrol/queryByOrderId",
    method: "get",
    params: data,
  });
}
//1.巡视工单巡视点列表查询
export function getPatrolPointList(data) {
  return request({
    url: "/eam-service-order/patrolPoint/queryList",
    method: "get",
    params: data,
    noLoading: true,
  });
}
//1.巡视点详情查询
export function getPatrolCPointDetail(data) {
  return request({
    url: "/eam-service-order/patrol/queryByPatrolPointId",
    method: "get",
    params: data,
    noLoading: true,
  });
}

//1.巡视点详情查询
export function downloadPatrolCheck(data) {
  return request({
    url: "/eam-service-order/patrol/downloadPatrolCheck",
    method: "get",
    params: data,
  });
}

//1.巡视工单报缺信息
export function getPatrolDefectList(data) {
  return request({
    url: "/eam-service-order/defect/queryList",
    method: "get",
    params: data,
  });
}

export function updatePatrolOrder(data) {
  return request({
    url: "/eam-service-order/patrol/baseInfo/update",
    method: "put",
    data: data,
  });
}

// 根据时间范围查询巡检任务列表
export function getPatrolOrderCalendarTasksByDate(data) {
  return request({
    url: "/eam-service-order/patrol/baseInfo/staPatrolInfo",
    method: "get",
    params: data
  })
}
